package tron.kafka;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class KafkaController {
    @Autowired
    KafkaSendServer kafkaSendServer;

    @GetMapping("/kafkaSend")
    public String send(String topic,String msg) {
        String result = kafkaSendServer.sendMsg(topic,msg);
        return result;
    }
}
